Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

require public key for signing only when necessary #499

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sisp
Copy link

@sisp sisp commented Jun 6, 2024

Signing a file with ssh-keygen -Y sign -n <namespace> -f <key_file> <file> does not actually require a public key when <key_file> is the path to a private key file, but ssh-keygen is currently failing when the public key file does not exist. To avoid being unnecessarily strict, I've moved the check for the existence of a public key file. Now, an attempt at loading the public key file is made in the same place as before, but its existence is only enforced when checking the SSH agent for the key. IIUC, this is the only place where the public key is required.

WDYT? 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant